package com.lovar.gaming.core.util;

import cn.hutool.extra.spring.SpringUtil;
import org.springframework.core.env.Environment;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * Spring常用工具
 *
 * @author Champagne9
 * @date 2024/3/8
 * @template
 */
@Component
public class SpringUtils extends SpringUtil {

    public static List<String> getSysLocales() {
        Environment environment = getApplicationContext().getEnvironment();
        List<String> property = environment.getProperty("system.languages", List.class);
        return property;
    }

}
